Skip to content

refactor(infra): Agentation 흐름과 시리즈 카드 정리 - #82

Merged
dev-wooyeon merged 2 commits into
masterfrom
codex/refactor-agentation-series
Mar 12, 2026
Merged

refactor(infra): Agentation 흐름과 시리즈 카드 정리#82
dev-wooyeon merged 2 commits into
masterfrom
codex/refactor-agentation-series

Conversation

@dev-wooyeon

Copy link
Copy Markdown
Owner

Summary

  • Agentation 개발 흐름을 same-origin 프록시와 단발 autorun 기준으로 정리했어요.
  • webhook autorun이 annotation 메타데이터를 프롬프트에 반영하고 stale 실행을 정리하도록 개선했어요.
  • 시리즈 허브 카드에서 중복 배지를 제거하고 링크 밀도를 조정했어요.
  • 시리즈 카드 구조를 검증하는 컴포넌트 테스트를 추가했어요.

Commits

  • refactor(agentation): same-origin sync 흐름 정리
  • refactor(blog): 시리즈 허브 카드 구조 정리

Testing

  • npm run build
  • npx eslint next.config.mjs src/app/api/agentation/webhook/route.ts src/shared/devtools/AgentationOverlay.tsx src/features/blog/ui/components/SeriesHubCard.tsx src/features/blog/ui/components/SeriesHubCard.test.tsx

Notes

  • docs/guides/agentation-workflow.md는 문서 파일이라 ESLint 대상에서 제외했어요.
  • npx vitest run src/features/blog/ui/components/SeriesHubCard.test.tsx 는 로컬 worker 시작 단계에서 html-encoding-sniffer / @exodus/bytes ESM 충돌로 실행되지 않았어요.

개발 환경에서 Agentation overlay를 same-origin 프록시로 연결했어요.
autorun webhook이 annotation 메타데이터를 프롬프트에 반영하고 stale 실행을 정리하도록 개선했어요.
로컬 개발 가이드도 현재 동작에 맞게 업데이트했어요.
시리즈 제목 앞의 중복 배지를 제거하고 에피소드 링크 여백을 정리했어요.
변경된 카드 구조를 검증하는 컴포넌트 테스트를 추가했어요.
@vercel

vercel Bot commented Mar 12, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
eunu-log Ready Ready Preview, Comment Mar 12, 2026 6:09am

@dev-wooyeon dev-wooyeon changed the title refactor: agentation 흐름과 시리즈 카드 정리 refactor(infra): Agentation 흐름과 시리즈 카드 정리 Mar 12, 2026
@dev-wooyeon
dev-wooyeon merged commit f08446e into master Mar 12, 2026
3 of 4 checks passed

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 385e5862de

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment on lines +131 to +134
if (isRunning && (isExpired || isIdle)) {
try {
process.kill(lock.pid, 'SIGTERM');
} catch {}

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P1 Badge Verify PID ownership before sending SIGTERM

When a lock is considered expired/idle, this code now unconditionally calls process.kill(lock.pid, 'SIGTERM') based only on the PID stored in .agentation/autorun.lock.json. If that lock survives long enough for PID reuse (e.g., after a crash/restart), a later webhook can terminate an unrelated local process that happens to have the same PID, which is a regression from the previous behavior that never killed running PIDs.

Useful? React with 👍 / 👎.


const isRunning = isPidRunning(lock.pid);
const isExpired = getLockAgeMs(lock) > AUTORUN_MAX_AGE_MS;
const isIdle = getAutorunIdleMs() > AUTORUN_IDLE_TIMEOUT_MS;

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Compute idle timeout from this run, not prior log mtime

Idle detection is based on autorun.log mtime, but starting a new child with openSync(..., 'a') does not update mtime until the process writes output. If another webhook arrives before the first log write, isIdle can be true immediately because the file still has an old timestamp from a previous run, causing a healthy fresh autorun to be killed and restarted.

Useful? React with 👍 / 👎.

@dev-wooyeon
dev-wooyeon deleted the codex/refactor-agentation-series branch April 13, 2026 06:33
dev-wooyeon added a commit that referenced this pull request Jul 24, 2026
* refactor(agentation): same-origin sync 흐름 정리

개발 환경에서 Agentation overlay를 same-origin 프록시로 연결했어요.
autorun webhook이 annotation 메타데이터를 프롬프트에 반영하고 stale 실행을 정리하도록 개선했어요.
로컬 개발 가이드도 현재 동작에 맞게 업데이트했어요.

* refactor(blog): 시리즈 허브 카드 구조 정리

시리즈 제목 앞의 중복 배지를 제거하고 에피소드 링크 여백을 정리했어요.
변경된 카드 구조를 검증하는 컴포넌트 테스트를 추가했어요.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant